<template>
  <div class="content">
    <!-- 公共组件-每个页面必须引入 -->
    <public-module></public-module>
	<div class="newInfo-page">
			<div class="new-title" >{{info.newsTitle}}</div>
			<div class="new-time">
				发布时间：{{info.createdAt}}
				<span style="padding-left:40rpx">阅读量：{{info.newsViewNum}}</span>
			</div>
			<div class="new-info">
				<u-parse :content="info.newsContent"></u-parse>
			</div>
			
	</div>
	
	
  </div>
</template>

<script>
  import {getNewsDetail,pageSeo} from '@/config/api.js' 
  import store from '@/store';
  export default {
    components: {
     

    },
    data() {
      return {
	     info:{}
	
	
	
      }
    },

	async onLoad(options) {
    	await this.$onLaunched;	

		getNewsDetail({newsId:options.newsId}).then((res)=>{
			this.info = res
		})
		// #ifdef H5
		pageSeo({pageType: 'newsDetailPage'}).then((res)=>{
			document.title = res.pageTitle;
		})
		// #endif	
    },

    methods: {
		
		
		
	}
	

  }
</script>

<style lang="scss" scoped>
@import '@/style/common.scss';
.newInfo-page{
	background: #fff;
	padding:36rpx;
	min-height: 100vh;
	.new-title{
		font-size: 28rpx;
		color: #000000;
	}
	.new-time{
		font-size: 22rpx;
		color: #8B8B8B;
		margin-top:20rpx;
	}
	.new-info{
		margin-top:40rpx;
		font-size: 24rpx;
		color:#000;
		line-height:1.5;
	}
	
}


</style>